from flask import jsonify
from flask import Flask
from flask_cors import CORS
from cofig import Config
from views.comany import bp_company
from views.user import bp_user

app = Flask(__name__)

CORS(app)
app.config.from_object(Config)
# 公司蓝图
app.register_blueprint(bp_company)
# 用户登录
app.register_blueprint(bp_user)


@app.route('/test')
def test():
    return jsonify({'code': '新的一天美滋滋11111111'})


if __name__ == '__main__':
    app.run(debug=True)
